package com.qf.android.sport.callback;

import com.qf.android.sport.entity.TitleTotal;
import com.qf.android.sport.entity.news.Root;
import com.qf.android.sport.entity.news.TotalEntity;
import com.qf.android.sport.entity.news.TwoNew;

import java.util.Map;

import retrofit2.Call;
import retrofit2.http.GET;
import retrofit2.http.Path;
import retrofit2.http.Query;
import retrofit2.http.QueryMap;

/**
 * Created by wuruyuan on 2016/12/15.
 */

public interface HttpService {
    @GET("http://api.lifxapi.com/tiyu/rest/channel/list?version=0&machine_code=865682026799303&client=key%3ATiyuForAndroid&version=2.11&format=json&app_id=4&is_emulator=false")
    Call<TitleTotal> getDatas();


    @GET("tiyu/rest/content/list")
    Call<TotalEntity> getData(@Query("channel_id") String channel_id, @Query("data_version") String data, @Query("contest_flag") String contest_flag, @Query("head_version") String head_version, @Query("data_version") String data_version, @Query("banner_flag") boolean banner_flag, @Query("machine_code") String machine_code, @Query("client") String client, @Query("version") String version, @Query("format") String format, @Query("app_id") String app_id, @Query("is_emulator") boolean is_emulator, @QueryMap Map<String, String> map);

    //    http://api.lifxapi.com/tiyu/rest/content/view?code=865682026799303&id=197145
//            &s_channel_id=0&comment=true&machine_code=865682026799303&client=key%3ATiyuForAndroid
//    &version=2.11&format=json&app_id=4&is_emulator=false
    @GET("tiyu/rest/content/{type}")
    Call<TwoNew> getNew(@Path("type") String type, @Query("id") long id);

    @GET("tiyu/rest/content/recommend")
    Call<Root> getroot(@Query("id") long id);

}
